hvm: Add PCI subsystem ID to emulated devices.
authorkfraser@localhost.localdomain <kfraser@localhost.localdomain>
Wed, 7 Feb 2007 16:08:47 +0000 (16:08 +0000)
committerkfraser@localhost.localdomain <kfraser@localhost.localdomain>
Wed, 7 Feb 2007 16:08:47 +0000 (16:08 +0000)
This patch adds the PCI Subsystem ID 5853:0001 to the virtual
devices emulated by qemu (ide, nic, vga).

Signed-off-by: Gerd Hoffmann <kraxel@suse.de>
tools/ioemu/hw/cirrus_vga.c
tools/ioemu/hw/ide.c
tools/ioemu/hw/rtl8139.c

index 3c316d6dc9ecf70b12ccc3292632b73a32cb2ebb..292673ae6a3662b0727541b4e431f7a285764695 100644 (file)
@@ -3339,6 +3339,10 @@ void pci_cirrus_vga_init(PCIBus *bus, DisplayState *ds, uint8_t *vga_ram_base,
     pci_conf[0x0a] = PCI_CLASS_SUB_VGA;
     pci_conf[0x0b] = PCI_CLASS_BASE_DISPLAY;
     pci_conf[0x0e] = PCI_CLASS_HEADERTYPE_00h;
+    pci_conf[0x2c] = 0x53; /* subsystem vendor: XenSource */
+    pci_conf[0x2d] = 0x58;
+    pci_conf[0x2e] = 0x01; /* subsystem device */
+    pci_conf[0x2f] = 0x00;
 
     /* setup VGA */
     s = &d->cirrus_vga;
index ef203a2f8aac0cf8a063600c8952f7ce3004d1f8..3bf2c7d5940421df57f4b5dad773d96739403f20 100644 (file)
@@ -2502,6 +2502,10 @@ void pci_piix3_ide_init(PCIBus *bus, BlockDriverState **hd_table, int devfn)
     pci_conf[0x0a] = 0x01; // class_sub = PCI_IDE
     pci_conf[0x0b] = 0x01; // class_base = PCI_mass_storage
     pci_conf[0x0e] = 0x00; // header_type
+    pci_conf[0x2c] = 0x53; /* subsystem vendor: XenSource */
+    pci_conf[0x2d] = 0x58;
+    pci_conf[0x2e] = 0x01; /* subsystem device */
+    pci_conf[0x2f] = 0x00;
 
     pci_register_io_region((PCIDevice *)d, 4, 0x10, 
                            PCI_ADDRESS_SPACE_IO, bmdma_map);
index 77e3c6d9fbb666c46ca4f9faa0a09510764300a6..e4ba40dfe3268c917e49833d8b791a931e4e622b 100644 (file)
@@ -3423,8 +3423,10 @@ void pci_rtl8139_init(PCIBus *bus, NICInfo *nd)
     pci_conf[0x0e] = 0x00; /* header_type */
     pci_conf[0x3d] = 1;    /* interrupt pin 0 */
     pci_conf[0x34] = 0xdc;
-    pci_conf[0x2c] = pci_conf[0x00]; // same as Vendor ID
-    pci_conf[0x2d] = pci_conf[0x01];
+    pci_conf[0x2c] = 0x53; /* subsystem vendor: XenSource */
+    pci_conf[0x2d] = 0x58;
+    pci_conf[0x2e] = 0x01; /* subsystem device */
+    pci_conf[0x2f] = 0x00;
 
     s = &d->rtl8139;